#include "skill.h"

Skill::Skill(const QString &name, QObject *parent) :
    DTwentyItem(name, parent),
    d(new Data())
{
}

Skill::Skill(int attribute, const QString &name, QObject *parent) :
    DTwentyItem(name, parent),
    d(new Data())
{
    d->attribute = attribute;
}

Skill::Skill(const Skill &other) :
    DTwentyItem(other),
    d(other.d)
{
}

int Skill::attribute() const
{
    if (d->attribute.isNull())
    {
        return -1;
    }

    return d->attribute.toInt();
}

void Skill::setAttribute(int attribute)
{
    d->attribute = attribute;
}


